package com.wl.api.controller.business;

import com.wl.api.common.utils.JsonObject;
import com.wl.api.controller.base.CommonController;
import com.wl.api.dto.base.CommonUserDTO;
import com.wl.api.service.system.ISecurityGradePriceService;
import com.wl.api.service.system.ISecurityGradeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * desc
 * Created by chenj on 2018/4/12.
 */
@RestController
@RequestMapping("/external/customer/grade/")
public class CustomerGradeController extends CommonController {

    @Autowired
    ISecurityGradeService gradeService;
    @Autowired
    ISecurityGradePriceService gradePriceService;

    @RequestMapping(value = "query")
    public JsonObject getCustomerGrade() throws  Exception {
        JsonObject json = JsonObject.getInstance();
        CommonUserDTO user = getCommonUser();
        gradeService.getGradeChannelFreeDiscountDetail(user.getGradeId());
        return json;
    }
}
